#define  _CRT_SECURE_NO_WARNINGS 1
#include"vector.h"
#include<iostream>
#include<vector>
using namespace std;
namespace gyc {

	void vector_test01()
	{
		vector<int> v;
		v.push_back(1);
		v.push_back(2);
		v.push_back(3);
		v.push_back(4);
		v.insert(v.begin()+1, 2);
		for (auto e : v)
		{
			std::cout << e << " ";
		}
		std::cout << std::endl;
		v.erase(v.end() - 1);

		for (auto e : v)
		{
			std::cout << e << " ";
		}
		std::cout << std::endl;
	}


	void vector_test02()
	{
		vector<int> v1 = { 1,2,3,4,5,6 };

		for (auto e : v1)
		{
			cout << e << " ";
		}
		cout << endl;

		vector<int>::iterator it = v1.begin();

		while (it != v1.end())
		{
			if (*(it) % 2 == 0)
			{
				it = v1.erase(it);
			}
			else {
				it++ ;
			}
		}

		for (auto e : v1)
		{
			cout << e << " ";
		}
		cout << endl;

	}


	void vector_test03()
	{
		vector<int> v2 = { 1,3,5 };
		//v2.resize(6);
		vector<int> v3(v2);
	}

}




	int main()
	{

		//int k(1);
          
		gyc::vector_test03();
		return 0;
	}

	